Foxit PDF SDK
FoxitPDFSDKPython2.Preflight Class Reference
Inheritance diagram for FoxitPDFSDKPython2.Preflight:
FoxitPDFSDKPython2.Base

Public Member Functions

def Preflight ()
 Constructor. More...
 
def Analyze (preflight_setting_data, progress_callback)
 Analyze a PDF file. More...
 
def AnalyzeAndFixup (preflight_setting_data, progress_callback)
 Analyze and fixup a PDF file. More...
 
def CanFixup (item_key)
 Check whether the item key can be fixuped or not. More...
 
def GenerateReport (preflight_report_setting_data, progress_callback)
 Generate report after analyzing or fixing. More...
 
def GenerateXMLReport (xml_report_file_path, progress_callback)
 Generate an XML report after analyzing or fixing. More...
 
def GetGroupItemComment (key)
 Get the comment of the group item through the key. More...
 
def GetGroupItemName (key)
 Get the name of the group item through the key. More...
 
def GetGroupNamesArray (library_type, operate_type)
 Get all group names array corresponding to the library type and operation type. More...
 
def GetItemKeysArray (group_name)
 Get item keys array with the specific group name. More...
 
def IsEmpty ()
 Check whether current object is empty or not. More...
 
def SetPreflightGroupLocalCallback (callback)
 Set a localized name and comment callback for preflight group items. More...
 

Detailed Description

This class represents the analysis and fix-up functions that match a specified industry profile and performs checks or fix-ups.

Constructor & Destructor Documentation

◆ Preflight()

def FoxitPDFSDKPython2.Preflight.Preflight ( )

Constructor.

Constructor, with another preflight object.

Parameters
[in]otherAnother preflight object.

Member Function Documentation

◆ Analyze()

def FoxitPDFSDKPython2.Preflight.Analyze (   preflight_setting_data,
  progress_callback 
)

Analyze a PDF file.

Parameters
[in]preflight_setting_dataThe preflight setting data.
[in]progress_callbackA ProgressCallback object which is implemented by user and can be used to get progress data.
Returns
A ResultInformation object.

◆ AnalyzeAndFixup()

def FoxitPDFSDKPython2.Preflight.AnalyzeAndFixup (   preflight_setting_data,
  progress_callback 
)

Analyze and fixup a PDF file.

Parameters
[in]preflight_setting_dataThe preflight setting data.
[in]progress_callbackA ProgressCallback object which is implemented by user and can be used to get progress data.
Returns
A ResultInformation object.

◆ CanFixup()

def FoxitPDFSDKPython2.Preflight.CanFixup (   item_key)

Check whether the item key can be fixuped or not.

Parameters
[in]item_keyThe item key. It can be retrieved by FoxitPDFSDKPython2.Preflight.GetItemKeysArray .
Returns
true means can be fixuped, while false means can not be fixuped.

◆ GenerateReport()

def FoxitPDFSDKPython2.Preflight.GenerateReport (   preflight_report_setting_data,
  progress_callback 
)

Generate report after analyzing or fixing.

This should be called after FoxitPDFSDKPython2.Preflight.Analyze or FoxitPDFSDKPython2.Preflight.AnalyzeAndFixup .

Parameters
[in]preflight_report_setting_dataThe preflight report setting data.
[in]progress_callbackA ProgressCallback object which is implemented by user and can be used to get progress data.
Returns
true means success, while false means failure.

◆ GenerateXMLReport()

def FoxitPDFSDKPython2.Preflight.GenerateXMLReport (   xml_report_file_path,
  progress_callback 
)

Generate an XML report after analyzing or fixing.

This should be called after FoxitPDFSDKPython2.Preflight.Analyze or FoxitPDFSDKPython2.Preflight.AnalyzeAndFixup .

Parameters
[in]xml_report_file_pathA complete path for saving the XML report file. This should not be an empty string.
[in]progress_callbackA ProgressCallback object which is implemented by user and can be used to get progress data. This can be null. Default value: null.
Returns
true means success, while false means failure.

◆ GetGroupItemComment()

def FoxitPDFSDKPython2.Preflight.GetGroupItemComment (   key)

Get the comment of the group item through the key.

Only English is available, and other languages need to reference the translated XML to get it by themselves.

Parameters
[in]keythe key of group item.
Returns
The comment of the group item obtained through the FoxitPDFSDKPython2.Preflight.GetGroupNamesArray and FoxitPDFSDKPython2.Preflight.GetItemKeysArray interface.

◆ GetGroupItemName()

def FoxitPDFSDKPython2.Preflight.GetGroupItemName (   key)

Get the name of the group item through the key.

Only English is available, and other languages need to reference the translated XML to get it by themselves.

Parameters
[in]keythe key of group item.
Returns
The name of the group item obtained through the FoxitPDFSDKPython2.Preflight.GetGroupNamesArray and FoxitPDFSDKPython2.Preflight.GetItemKeysArray interface.

◆ GetGroupNamesArray()

def FoxitPDFSDKPython2.Preflight.GetGroupNamesArray (   library_type,
  operate_type 
)

Get all group names array corresponding to the library type and operation type.

Parameters
[in]library_typeThe library type. Please refer to values starting from FoxitPDFSDKPython2.PreflightSettingData.e_LibraryTypeFoxit and this should be one of these values.
[in]operate_typeThe operate type. Please refer to values starting from FoxitPDFSDKPython2.PreflightSettingData.e_OperateTypeProfiles and this should be one of these values.
Returns
The group names array.

◆ GetItemKeysArray()

def FoxitPDFSDKPython2.Preflight.GetItemKeysArray (   group_name)

Get item keys array with the specific group name.

Parameters
[in]group_nameThe group name which can obtain from the function FoxitPDFSDKPython2.Preflight.GetGroupNamesArray .
Returns
The item keys array.

◆ IsEmpty()

def FoxitPDFSDKPython2.Preflight.IsEmpty ( )

Check whether current object is empty or not.

When the current object is empty, that means current object is useless.

Returns
true means current object is empty, while false means not.

◆ SetPreflightGroupLocalCallback()

def FoxitPDFSDKPython2.Preflight.SetPreflightGroupLocalCallback (   callback)

Set a localized name and comment callback for preflight group items.

This callback is used by FoxitPDFSDKPython2.Preflight.GetGroupItemName and FoxitPDFSDKPython2.Preflight.GetGroupItemComment to provide localized names and comments for group items. When a localized string for a given key is available from the callback, it will be used; otherwise, the default library string will be used.

Parameters
[in]callbackA PreflightGroupLocalCallback callback object that provides localized names and comments.
Returns
None.